﻿using System.Web;
using System.Web.Http.WebHost;
using System.Web.Routing;

namespace BoxSauce.AgencyToolkit.Web.Mvc
{
    public class CustomApiHttpControllerRouteHandler : HttpControllerRouteHandler
    {
        protected override IHttpHandler GetHttpHandler(RequestContext requestContext)
        {
            requestContext.RouteData.Values["controller"] = requestContext.RouteData.Values["controller"].ToString() + "Api";

            return base.GetHttpHandler(requestContext);
        }
    }
}
